package d1023;

public class StudentTest {
    public static void main(String[] args) {
		/*Student stu =new Student ("美丽");
	System.out.println(stu.name);

	Student stu1=new Student();
	System.out.println(stu1.name+stu1.age);*/

	/*Student stu2=new Student("张三",20);
	System.out.println(stu2.name+stu2.age);
	//将stu2的name设置成李四，年龄修改成21
	stu2.name="李四";
	stu2.age=21;  //封装
	System.out.println(stu2.name+stu2.age);*/

        Student stu1=new Student ("张三",20);
        System.out.println(stu1.getName());
	/*stu1.setName("张三丰");
	System.out.println(stu1.getName());
	*/
    }
}
